package com.springboot.frame.web.csrf;

import lombok.Getter;
import org.springframework.util.Assert;

@Getter
public final class CsrfToken {

  private String token;

  private String parameterName;

  private String headerName;

  public CsrfToken(String headerName, String parameterName, String token) {
    Assert.hasLength(headerName, "headerName cannot be null or empty");
    Assert.hasLength(parameterName, "parameterName cannot be null or empty");
    Assert.hasLength(token, "token cannot be null or empty");
    this.headerName = headerName;
    this.parameterName = parameterName;
    this.token = token;
  }

}
